################################################################################
##
## Mod Title:		Update Advanced Visual Confirmation 1.1.0 to 1.1.1
## Mod Author:		AmigaLink < webmaster@amigalink.de > (Markus Schmidt) http://www.EssenMitFreude.info
##
################################################################################
##
##  The following sites also contain the latest version of this MOD: 
## 
##  http://www.AmigaLink.de
##  http://www.phpBB.de
##  http://www.phpBBhacks.com
## 
##  Full support for this MOD can be obtained at: 
##
##  http://www.AmigaLink.de
##
################################################################################
##
##  BEFORE ADDING THIS HACK TO YOUR FORUM, please be sure to backup ALL
##  affected files.
##
################################################################################
#
#----------[ PLEASE NOTE ]------------------------------
#
# At least GD library 1.6 with freetype are needed!
# For JPEG are GD 1.8 needed.
# If you have PHP lower than 4.0.6 deactivate the Ellipses.
#
#
#----------[ COPY FILES ]-------------------------------
#
#  Copy / upload the following files to your phpBB root directory.
#  The phpBB root directory is the directory on your server containing index.php
#

admin/admin_captcha_config.php to admin/admin_captcha_config.php
includes/usercp_confirm.php to includes/usercp_confirm.php
language/lang_english/lang_admin_captcha.php to language/lang_english/lang_admin_captcha.php
language/lang_german/lang_admin_captcha.php to language/lang_german/lang_admin_captcha.php
templates/subSilver/admin/admin_captcha_config.tpl to templates/subSilver/admin/admin_captcha_config.tpl

#
#----------[ SQL ]--------------------------------------
#
#  Run the following SQL statement to update your phpBB database.
#  You can use phpMyAdmin or a similar tool to run this update.
#
#  IMPORTANT: If you have changed the table prefix from the default of phpBB2,
#  please be sure to replace phpbb with your prefix BEFORE running this update.
#

ALTER TABLE `phpbb_confirm` CHANGE `code` `code` CHAR(10) NOT NULL;

#
#----------[ OPEN ]-------------------------------------
#

includes/usercp_register.php

#
#----------[ FIND ]-------------------------------------
#

		// Generate the required confirmation code
		// NB 0 (zero) could get confused with O (the letter) so we make change it
		$code = dss_rand();
		$code = substr(str_replace('0', 'Z', strtoupper(base_convert($code, 16, 35))), 2, 6);

#
#----------[ REPLACE WITH ]-----------------------------
#

		// Generate the required confirmation code
		$code_length = rand(4, 6);
		$code = dss_rand();
		$code = strtoupper(base_convert($code, 16, 35));
		$code = str_replace('I', '', $code); // The letter I could get confused with the letter J and the number 1 (one) so we remove it
		$code = str_replace('0', '', $code); // NB 0 (zero) could get confused with O (the letter) so we remove it
		$code = substr($code, 2, $code_length);

#
#----------[ OPEN ]-------------------------------------
#

templates/subSilver/profile_add_body.tpl

#
#----------[ FIND ]-------------------------------------
#

	  <td class="row2"><input type="text" class="post" style="width: 200px" name="confirm_code" size="6" maxlength="6" value="" /></td>

#
#----------[ REPLACE WITH ]-----------------------------
#

	  <td class="row2"><input type="text" class="post" style="width: 200px" name="confirm_code" size="10" maxlength="10" value="" /></td>

#
#----------[ SAVE AND CLOSE ALL FILES ]-----------------
#
# EoM